Skip to content

test(writer): mutation-cover WriteRegistry — writer scope to 100%#98

Merged
dfa1 merged 1 commit into
mainfrom
pitest-writer-more
Jun 20, 2026
Merged

test(writer): mutation-cover WriteRegistry — writer scope to 100%#98
dfa1 merged 1 commit into
mainfrom
pitest-writer-more

Conversation

@dfa1

@dfa1 dfa1 commented Jun 20, 2026

Copy link
Copy Markdown
Owner

Follow-up to #97. Adds WriteRegistry to the writer pitest scope and closes its gaps.

Finding

WriteRegistry started at 95% (exercised indirectly via loadAll), with three survivors no test pinned:

  • register(EncodingEncoder) / register(ExtensionEncoder) return this — nothing asserted the fluent builder return, so the NullReturn mutant survived.
  • empty() — NO_COVERAGE; no test used the empty factory.

Fix

WriteRegistryTest (BDDMockito mock encoders/extensions) covers registration, duplicate-id rejection, extension lookup, the same-builder fluent returns, and the empty() / loadAll() factories.

Result

Writer 64/64 mutations killed (ChunkImpl + WriteRegistry), test strength 100%, 0 no-coverage.

Verify

./mvnw -pl writer -am -P pitest verify

🤖 Generated with Claude Code

Add WriteRegistry to the writer pitest scope. It started at 95% (exercised
indirectly via loadAll), with three survivors no test pinned:
- register(EncodingEncoder) / register(ExtensionEncoder) `return this` —
  nothing asserted the fluent builder return (NullReturn survived).
- empty() — NO_COVERAGE; no test used the empty factory.

WriteRegistryTest covers registration, duplicate-id rejection, extension
lookup, the same-builder fluent returns, and the empty/loadAll factories,
using mock encoders/extensions (BDDMockito).

Writer now 64/64 mutations killed (ChunkImpl + WriteRegistry), strength 100%.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@dfa1 dfa1 merged commit 912fcaf into main Jun 20, 2026
6 checks passed
@dfa1 dfa1 deleted the pitest-writer-more branch June 20, 2026 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant